<!DOCTYPE HTML>
<html lang="zh-CN">
<head>
	<meta charset="utf-8" />
	<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
	<meta name="apple-mobile-web-app-capable" content="yes" />
	<meta name="apple-mobile-web-app-status-bar-style" content="black" />
	<meta name="format-detection" content="telephone=no" />
	<meta http-equiv="x-dns-prefetch-control" content="on" />
	<link rel="stylesheet" type="text/css" href="{$Think.config.RESOURCEURL}wx_assets/css/common.css{$Think.config.RESOURCE_VER}" />
	<link href="{$Think.config.RESOURCEURL}wx_assets/micontent/materiaDetail.css{$Think.config.RESOURCE_VER}" rel="stylesheet">
	<link rel="stylesheet" type="text/css" href="{$Think.config.RESOURCEURL}wx_assets/css/product/mall.css{$Think.config.RESOURCE_VER}" />
	<!-- <script src="http://sdk.talkingdata.com/app/h5/v1?appid=DE13C350F41F5DE78FEC51DB5DE730D1&vn=v2&vc=v2"></script> -->
	<script type="text/javascript" src="{$Think.config.RESOURCEURL}wx_assets/js/alertMsg.js{$Think.config.RESOURCE_VER}"></script>
	<script type="text/javascript" src="{$Think.config.RESOURCEURL}wx_assets/js/zepto.1.1.3.min.js{$Think.config.RESOURCE_VER}"></script>
	<script type="text/javascript" src="{$Think.config.RESOURCEURL}wx_assets/js/zepto.alert.js{$Think.config.RESOURCE_VER}"></script>
	<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
	<script src="{$Think.config.RESOURCEURL}wx_assets/js/util.js{$Think.config.RESOURCE_VER}" type="text/javascript"></script>
    <script type="text/javascript" src="{$Think.config.RESOURCEURL}wx_assets/js/wx_share.js{$Think.config.RESOURCE_VER}"></script>
	<script type="text/javascript" src="{$Think.config.RESOURCEURL}wx_assets/js/product/product_single_list.js{$Think.config.RESOURCE_VER}"></script>
	<script src="{$Think.config.RESOURCEURL}wx_assets/js/product/timer.js{$Think.config.RESOURCE_VER}" type="text/javascript"></script>    
	<title>【密友圈商城】</title>
</head>
<style>
	.taggroup
	{
		position: absolute;
		top: 0px;
		left: 0px;
		padding:0px 0px;
		height: 38px;
		overflow: hidden;
	}
	.taggroup > span
	{
		display: block;
		padding: 2px 7px;
		background: #ff8f12;
		color: white;
		position: relative;
		margin: 0px 5px;
		margin-left: 0px;
		margin-bottom: 40px;
		float: left;
	}
	.taggroup > span img
		{
			min-height: 11px;
			height: 11px;
			width: 100%;
			position: absolute;
			bottom: -11px;
			display: block;
			width: 100%;
			left: 0px;
			right: 0px;
		}
	/*.taggroup > span:after
	{
		content: '';
		background: url({$Think.config.RESOURCEURL}wx_assets/indiana/images/tag.png) no-repeat;
		background-size: contain;
		width: 100%;
	    height: 18px;
	    
	    position: absolute;
	    bottom: -18px;
	    left: 0px;
	}*/
	.taggroup > span p
	{
		position: relative;
		top:5px;
	}
	.iteamInfo a .ico-iteam
	{
		background: white;
	}
	.iteamInfo a .ico-iteam p
	{
		font-size: 12px;
		color: #FF8F12;
		margin-top: 2px;
		text-align: center;
		line-height: 15px;
	}
	.iteamInfo a .iteamPrice
	{
		font-size: 12px;
		text-decoration: line-through;
		padding: 0px 6px;
	}
	.iteamInfo a .iteamNum
	{
		border: 0px;
		padding-right: 0px;
		border: 0px;
		padding-right: 0px;
		height: 33px;
		line-height: 33px;
		font-size: 22px;
		margin:0;
	}
	.iteamInfo a .iteamNum i{
		font-size:14px;
	}
	.iteamInfo a .toIteam
	{
		background: transparent;
	}
	.iteamInfo a .toIteam:after
	{
		width: 7px;
		height: 7px;
		top: 13px;
	}
	.seckillTime
		{
			position: absolute;
			top: 5px;
			height: 30px;
			background: rgba(0,0,0,0.7);
			width: 120px;
			color: white;
			border-top-right-radius: 17px;
			border-bottom-right-radius:17px;
			font-size: 12px;
		}
		.seckillTime span
		{
			font-size: 12px;
			text-indent: 2px;
			text-align: left;
			line-height: 30px;
		}
		.seckillTime i.timeicon
		{
			display: inline-block;
			width: 23px;
			height: 23px;
			background: url({$Think.config.RESOURCEURL}wx_assets/indiana/images/iconfont-time.png) no-repeat;
			background-size:contain;
			vertical-align: middle;
			position: relative;
			top: -1px;
		}
		.seckillTime i.lxftime
		{
			font-weight: normal;
			font-size: 12px !important;
			font-style: normal;
			margin-left: 0px;
		}
		.seckillTime i.lxftime b
		{
			font-size: 12px;
			font-weight: normal;
		}
</style>
<body>
	<!--关注浮层 begin-->
	<!--0表示未关注，1表示已关注-->
	<if condition="$selfInfo.subscribe eq '0'">
	<style>
		.careview
		{
			position: fixed;
			top: 0px;
			left: 0px;
			right: 0px;
			padding: 8px 110px 8px 65px;
			background: rgba(0,0,0,0.5);
			z-index: 999;
			color: white;
			height: 61px;
			box-sizing: border-box;
		}
		.careview > span
		{
			content: '';
			display: block;
			position: absolute;
			top: 50%;
			right: 5px;
			background: url({$Think.config.RESOURCEURL}wx_assets/images/careclose.png) no-repeat;
			width:18px;
			height: 18px;
			margin-top: -9px;
			background-size: contain;
			opacity: 0.8;
		}
		.careview > img
		{
			display: block;
			
			width: 45px;
			height: 45px;
			border-radius: 4px;
			position: absolute;
			top: 50%;
			left: 10px;
			margin-top: -22px;
		}
		.careview > a
		{
			background: #1c93ce;
			display: block;
			color: white;
			text-align: center;
			border-radius: 4px;
			width: 75px;
			height: 35px;
			line-height: 35px;
			font-size: 14px;
			top: 50%;
			margin-top: -17px;
			right:35px;
			position: absolute;
			
		}
		.careview > p
		{
			display: inline-block;
			vertical-align: middle;
			font-size: 14px;
			padding: 3px 0px;
			max-height: 38px;
			overflow: hidden;
			height: 100%;
			line-height: 38px;
		}
	</style>
	<div class="careview">
		<img src="{$mallInfo.logo}" alt="" />
		<a href='{$mallInfo.wechaturl}'>立即关注</a>
		<empty name="mallInfo.recommend">
			<p>{$mallInfo.wechatname}</p>
			<else />
			<p>{$mallInfo.recommend}</p>
		</empty>
		<span></span>
	</div>
	<script>
		$('.careview > span').on('click',function(){
			$('.careview').hide();
		});
	</script>
	</if>
	<!--关注浮层 end-->
<div class="WX_bar J_topbar">
	<!--<div class="WX_cat J_smenu">-->
		<!--<div class="WX_cat_pop WX_cat_list J_smenu_list">-->
		<!--</div>-->
	<!--</div>-->
	<div class="WX_nav">
		<a class="" href="javascript:;" id="mcTab" >{$title}</a>
	</div>

</div>
<div class="WX_con" id="J_main">

	<div class="top_ad">
	<notempty name="headerpic">
		<a href="">
		<img src="{$headerpic}" alt="" />
		</a>
	</notempty>
	</div>
	<div class="top_menu">
		<ul>
			<li>
				<a href="http://www.mboxone.com/wx/call.html?userName=&customerId=19&module=webPage&method=getWebPage&params=%7B%22id%22:7%7D">
					<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/top_menu_1.png{$Think.config.RESOURCE_VER}">
				</a>
			</li>
			<li>
				<a href="http://www.mboxone.com/wx/call.html?userName=&customerId=19&module=webPage&method=getWebPage&params=%7B%22id%22:8%7D">
					<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/top_menu_2.png{$Think.config.RESOURCE_VER}">
				</a>
			</li>
			<li>
				<a href="http://www.mboxone.com/wx/call.html?userName=&customerId=19&module=webPage&method=getWebPage&params=%7B%22id%22:9%7D">
					<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/top_menu_3.png{$Think.config.RESOURCE_VER}">
				</a>
			</li>
			<li>
				<a href="http://www.mboxone.com/wx/call.html?userName=&customerId=19&module=webPage&method=getWebPage&params=%7B%22id%22:10%7D">
					<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/top_menu_4.png{$Think.config.RESOURCE_VER}">
				</a>
			</li>
		</ul>
	</div>
	<div class="jx">
        <volist name="item" id="item" key="k">
		<div class="jx_list" id="itemCont">
			<volist name="item.productList" id="product">
			<div class="jx_g" id="show_container{$k}">
				<a  onclick="product.toDetail('{$product.id}')" class="J_bi_product_item J_ytag" >
				<div class="jx_g_img">
					<if condition="$product['playType'] eq 4">
                        <div class="seckillTime" style="text-align: center;">
							<span style="text-align: center;"><!--<i class="timeicon"></i>-->
								<if condition="$product['seckillIsEnd'] neq '1'">
									<if condition="$product['seckillIsStart'] eq '1'">
										<i class="lxftime" nowtime="{$product.nowTime}" endtime="{$product.seckillEndtime}" col="0" lxfday="no" lxftex="距结束"></i>
									<else />
										 <!--{$product.seckillStartTime}-->
										<!-- <php>echo date("H:i:s",strtotime($product["seckillStartTime"]));</php>-->
										<i class="lxftime" nowtime="{$product.nowTime}" endtime="{$product.seckillStartTime}" col="0" lxfday="no" lxftext="距开始"></i>
										 
									</if>
								<else />
								 已抢完
								</if>
							</span>
                        </div>                    	
                    <else />
					<div class="taggroup">
					<volist name="product.picTag" id="pct">
						<span>
							<p>{$pct}</p>
							<i><img src="{$Think.config.RESOURCEURL}wx_assets/indiana/images/tag.png" alt="" /></i>
						</span>
					</volist>
					</div>
					</if>
                	<img class="" src="{$product.picUrl}" title="{$product.name}" />
				</div>
                </a>
				<div class="jx_g_info" style="padding-bottom:35px">
                <div   class="J_bi_product_item J_ytag" onclick="product.toDetail('{$product.id}')">
					<if condition="$product.playType eq '3'">
						<p class="jx_g_title">
							<if condition="$product.playType eq '3'">
								<span class="indianaState">夺宝</span>&nbsp;
							</if>
							{$product.title}
						</p>
						<notempty name="product.description">
							<p class="jx_g_name">{$product.description}</p>
						</notempty>
						<div class="indianaInfo">
							<div class="bar">
								<span style="width:{$product.barProgress}"></span>
							</div>
							<div class="partakeCount">
								<span>总需{$product.totalCopies}人次</span>
								<span>剩余<label style="color:#009ddf">{$product.beenSold}</label></span>
							</div>
						</div>
						<div class="btn_panic_div">
							<span class="btn_panic">立即抢购</span>
						</div>
					<elseif condition="$product.freeBuy eq '1'"/>
						<p class="jx_g_title">
							<if condition="$product.freeBuy eq '1'">
								<span class="freebuy">我要代言</span>&nbsp;
							</if>
							{$product.title}
						</p>
						<notempty name="product.description">
							<p class="jx_g_name">{$product.description}</p>
						</notempty>
						<p class="jx_g_price">
							<span class="jx_g_price_wx">
								密友价
								<span>
								<i>&yen;</i>
								<php>
								     $freeBuyMoney = explode(",",$product['freeBuyMoney']);
									 if(count($freeBuyMoney) > 1) {
											echo $freeBuyMoney[0].'~<i>&yen;</i>'.end($freeBuyMoney);
									 } else {
											echo $freeBuyMoney[0];
									 }
								</php>
								</span>
							</span>
							<del class="jx_g_price_market">市场价&yen;{$product.fixedPrice}</del>
						</p>
						<if condition = "($showBtn eq 1)">
							<notempty name = "product.fixedPrice">
								<a class="WX_btn jx_g_btn J_bi_product_item J_ytag j_cart"  onclick="product.loadProInfo('{$product.id}','{$product.freeBuy}')">加入购物车</a>
								<!--<a class="WX_btn jx_g_btn J_bi_product_item J_ytag"  onclick="product.toDetail({$product.id})">我想吃</a>-->
							</notempty>
						</if>
					<elseif condition="$product.teambuy eq '1'"/>
						<div class="iteamInfo">
						<a>
						<div class="ico-iteam">
							<p>{$product.teamCount}<br />人团</p>
						</div>
						<div class="iteamNum"><i>&yen;</i>{$product.teamPrice}
							<del style="font-size:12px;color:#fff;margin:0 6px;"><i>&yen;</i>{$product.fixedPrice}</del>
						</div>
						<div class="toIteam" onclick="product.toDetail('{$product.id}')">去组团</div>
						</a>
						<!--<del class="fixedPrice">原价&yen;{$product.fixedPrice}</del>-->
						</div>
					<elseif condition="($product.fixedPrice neq NULL)" />
					<notempty name="product.discountedPrice">
						<p class="jx_g_price">
							<span class="jx_g_price_wx">
								密友价
								<span>
								<i>&yen;</i>{$product.discountedPrice}
								</span>
							</span>
							<del class="jx_g_price_market">市场价&yen;{$product.fixedPrice}</del>
						</p>
		        		<p class="prices_divide">
		        		</p>
						<if condition = "($showBtn eq 1)">
							<notempty name = "product.fixedPrice">
								<a class="WX_btn jx_g_btn J_bi_product_item J_ytag j_cart"  onclick="product.loadProInfo('{$product.id}','{$product.freeBuy}')">加入购物车</a>
								<!--<a class="WX_btn jx_g_btn J_bi_product_item J_ytag"  onclick="product.toDetail({$product.id})">我想吃</a>-->
							</notempty>
						</if>
               		 </notempty>
                   	<empty name="product.discountedPrice">

		        		<p class="jx_g_price">
							<span class="jx_g_price_wx">
								市场价
								<span>
								<i>&yen;</i>{$product.fixedPrice}
								</span>
							</span>
						</p>
						<if condition = "($showBtn eq 1)">
							<notempty name = "product.fixedPrice">
								<a class="WX_btn jx_g_btn J_bi_product_item J_ytag j_cart"  onclick="product.loadProInfo('{$product.id}','{$product.freeBuy}')">加入购物车</a>
								<!--<a class="WX_btn jx_g_btn J_bi_product_item J_ytag"  onclick="product.toDetail({$product.id})">我想吃</a>-->
							</notempty>
						</if>
                   	</empty>
	             <else />
                 </if>
					</div>
				</div>
			</div>
			</volist>
		</div>
        </volist>

	</div>
</div>
<div class="cartInfo" id="cartInfo">
	<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/ico-cart.png">
	<div class="proNum"></div>
	<div class="proPrice">应付&nbsp;<i>&yen;</i><span></span>元</div>
	<div class="proPrice">实付&nbsp;<i>&yen;</i><span></span>元</div>
</div>
<div id="prompt" class="prompt">
	<div class="comment">
		“一元抢购”的玩法
	</div>
	<div class="way">
		<img src="{$Think.config.RESOURCEURL}wx_assets/images/product/way.png{$Think.config.RESOURCE_VER}">
	</div>
	<a>我知道了</a>
	<div class="menu">
		<input type="checkbox">以后不再提示
	</div>
</div>
<div class="productInfo" style="display:none" id="productInfo">
</div>
<script>
	lxfEndtime();
</script>
<script type="text/html" id="productInfoTpl">
	<div class="main">
		<div class="info">
			<div class="closeDiv"><div class="close" id="close"></div></div>
			<div class="imgDiv" align="center" onclick="product.toDetail('<%=fromCustomerId%>','<%=id%>')">
				<img src="<%=picUrl%>">
			</div>
			<div class="p-name">
				<div class="title" >
					<%if(freeBuy){%>
						<span class="freebuy">由你定价</span>&nbsp;
					<%}%>
					<%=name%>
				</div>
				<div class="price"><i>&yen;</i><% if(discountedPrice) {%>
					<%=discountedPrice%>
					<%} else {%>
					<%=fixedPrice%>
					<%}%>
					元</div>
			</div>
		</div>
		<%if(supportSpecification=="1"){%>
		<div class="mod_property" id="prop-list">
			<%if(size && size!='null'){%>
			<dl class="size">
				<dt><%=sizeUnit%></dt>
				<%if(sizeObj){
				for(var i=0;i<sizeObj.length;i++){
				var name=sizeObj[i];
				var url = sizeUrl[i];
				%>
				<%if(sizeUrl[0]){%>
				<dd data-name="<%=name%>"><img src="<%=url%>"><label><%=name%></label></dd>
				<%}else{%>
				<dd data-name="<%=name%>"><%=name%></dd>
				<%}%>
				<%}%>
				<%}%>
			</dl>
			<%}%>
			<%if(color && color!='null'){%>
			<dl class="color">
				<dt><%=colorUnit%></dt>
				<%if(colorObj){
					for(var i=0;i<colorObj.length;i++){
					var name=colorObj[i];
					var url = colorUrl[i];
					%>
						<%if(colorUrl[0]){%>
						<dd data-name="<%=name%>"><img src="<%=url%>"><label><%=name%></label></dd>
						<%}else{%>
						<dd data-name="<%=name%>"><%=name%></dd>
						<%}%>
					<%}%>
				<%}%>
			</dl>
			<%}%>
		</div>
		<%}%>
		<%if(freeBuy){%>
		<dl id="free-list">
			<dt>请选择价格</dt>
			<%var freeMoney = format(freeBuyMoney);
			if(freeMoney){
			for(var i=0;i<freeMoney.length;i++){
			var money = freeMoney[i];
			%>
			<%if(discountedPrice){%>
				<dd data-value="<%=money%>" data-price="<%=discountedPrice%>"><%=money%></dd>
				<%}else{%>
				<dd data-value="<%=money%>" data-price="<%=fixedPrice%>"><%=money%></dd>
			<%}%>
			<%}%>
			<%}%>
			<dt id="invitation" style="display:none;margin-bottom:0;"></dt>
		</dl>
		<%}%>
		<div class="buyNum">
			<div class="title">购买数量</div>
			<div class="numDiv">
				<a class="sub disabled" tag="sub" id="sub"></a>
				<input type="number" min="1" max="10000" step="1" value="1" class="num" id="buyNum"/>
				<a class="plus <%if(inventory && supportSpecification=="0" && inventoryCount<2){%>disabled<%}%>" tag="add" id="plus"></a>
			</div>
			<%if(inventory){%>
			<span class="inventory" id="inventory_count" <%if(supportSpecification=="0" && inventoryCount>0){%>style='display:block'<%} else {%>style="display:none"<%}%>>&nbsp;剩余<span id="stock-num"><%=inventoryCount%></span>件</span>
			<div class="soldOut" <%if(supportSpecification=="0" && !inventoryCount){%>style='display:block'<%} else {%>style="display:none"<%}%>></div>
		<%}%>
	</div>
	</div>
	<div data-id="<%=id%>" class="beSure <%if(inventory && supportSpecification=="0" && !inventoryCount){%>btn_disabled<%}%>" id="buy-now">确定</div>
	</div>
</script>
<script>
	<if condition="$prodetail neq ''">
		var pros={$prodetail};
	<else/>
		var pros={};
	</if>
var miUId = "{$fromUId}";
var qId = "{$qId}";
var baseUrl = '{$Think.config.SERVER_HOST}';
var hrefPath = baseUrl+'call.html?';
	template.helper("format",function(freeBuyMoney){
		return (freeBuyMoney || "").split(",");
	})
product.init();
</script>
<script type="text/javascript">
	function getShareUrl(){
		var p=$.util.getParamAsObject();
		if(p.qId){
			var params={
				"fromGuid": p.fromGuid,
				"qId":p.qId,
				"id": p.sId,
				"miUId":p.miUId,
				"pid": p.id,
				"module":"mall",
				"method":"getMall",
				"customerId":"{$customerId}"
			};
			params=encodeURIComponent(JSON.stringify(params));
			var shareUrl=baseUrl+'call.html?customerId={$platCustomerId}&module=quan&scope=1&method=goToCustomer&params='+params;
		}else{
			var shareUrl = location.href;
		}
		return shareUrl;
	}
	var shareUrl = getShareUrl();
wx_share.init({
    "title":'有个问题：如何只花1块钱买到小米手机？点我查看攻略',
    "desc":'雷军哭晕在厕所，小米系列的产品遭遇恶意甩卖.........',
    "link":shareUrl,
    "imgUrl":"{$headerpic}",
    "pkg":{
        "appId": '{$pkg.appId}',
        "timestamp": {$pkg.timestamp},
        "nonceStr": '{$pkg.nonceStr}',
        "signature": '{$pkg.signature}'
    },
    success:function(config,shareType){

    }
});

</script>

</body>
</html>
